package test04.sync.test05.t2;

/**
 *
 * 表达的是多个售票窗口各自出售各自的 50 张票 - (不太符合现实) - 多个线程操作公共相同的资源
 *
 * @Author lzp
 * @Date 2024-03-21
 */
public class Test {
    public static void main(String[] args) {

        Film f = new Film();

        //创建线程类
        WindowThread t1 = new WindowThread(f,"窗口一"); // t1 - piao = 50
        WindowThread t2 = new WindowThread(f,"窗口二"); // t2 - piao
        WindowThread t3 = new WindowThread(f,"窗口三"); // t3 - piao

        //启动线程
        t1.start();
        t2.start();
        t3.start();
    }
}
